﻿/*
Copyright (c) [2019年5月1日] [吴超]
[MBT_studio] is licensed under Mulan PSL v2.
You can use this software according to the terms and conditions of the Mulan PSL v2.
You may obtain a copy of Mulan PSL v2 at:
		 http://license.coscl.org.cn/MulanPSL2
THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
See the Mulan PSL v2 for more details.
*/


#pragma once




#include "向量.h"


#include "chrono/core/ChRealtimeStep.h"
#include "chrono/physics/ChBodyEasy.h"
#include "chrono/physics/ChLinkDistance.h"
#include "chrono/physics/ChLinkMotorRotationTorque.h"
#include "chrono/physics/ChSystemNSC.h"

#include "../../../S_Physics.h"








struct S_Chrono长方体几何体 : public S_物理几何体 {
	vec3	m_长宽高;
	float32	m_密度;

	void*	f_get几何体物理对象() { return 0; }
	//void	f_set几何体物理数据(void* data);
	bool	f_is空() {
		return false;
		//if (m_plane.distance(m_plane.n) <= 0) return true;
		//else return false;
	};
	S_Chrono长方体几何体(const vec3& ckg, float32 密度=1.0);
};






struct S_Chrono凸壳几何体 : public S_物理几何体 {
	float32	m_密度;
	std::vector<chrono::ChVector<>> m_Points;

	void*	f_get几何体物理对象() { return 0; }
	//void	f_set几何体物理数据(void* data);
	bool	f_is空() {
		return false;
		//if (m_plane.distance(m_plane.n) <= 0) return true;
		//else return false;
	};
	S_Chrono凸壳几何体(const S_三角Mesh& v, float32 密度 = 1.0);
};
















